import 'dart:convert';
import 'package:flutter_jdshop/generated/json/base/json_field.dart';
import 'package:flutter_jdshop/generated/json/banner_bean.g.dart';

@JsonSerializable()
class BannerBean {

	late List<BannerResult> result;
  
  BannerBean();

  factory BannerBean.fromJson(Map<String, dynamic> json) => $BannerBeanFromJson(json);

  Map<String, dynamic> toJson() => $BannerBeanToJson(this);

  @override
  String toString() {
    return jsonEncode(this);
  }
}

@JsonSerializable()
class BannerResult {

	@JSONField(name: "_id")
	late String sId;
	late String title;
	late String status;
	late String pic;
	late String url;
  
  BannerResult();

  factory BannerResult.fromJson(Map<String, dynamic> json) => $BannerResultFromJson(json);

  Map<String, dynamic> toJson() => $BannerResultToJson(this);

  @override
  String toString() {
    return jsonEncode(this);
  }
}